Platform Explorer / Nuxeo Platform 2023.22

Operation Document.Mail (Send E-Mail)

Description

Send an email using the input document to the specified recipients. You can use the HTML parameter to specify whether you message is in HTML format or in plain text. Also you can attach any blob on the current document to the message by using the comma separated list of xpath expressions 'files'. If you xpath points to a blob list all blobs in the list will be attached. Return back the input document(s). If rollbackOnError is true, the whole chain will be rollbacked if an error occurs while trying to send the email (for instance if no SMTP server is configured), else a simple warning will be logged and the chain will continue.
Operation id Document.Mail
AliasesNotification.SendMail
Category Notification
Label Send E-Mail
Requires
Since

Parameters

Name Description Type Required Default value
from string yes  
message string yes  
subject string yes  
HTML boolean no false 
Strict User Resolution boolean no  
bcc stringlist no  
cc stringlist no  
files stringlist no  
replyto stringlist no  
rollbackOnError boolean no true 
to stringlist no  
viewId string no view_documents 

Signature

Inputs document, documents
Outputs document, documents

Implementation Information

Implementation Class Class: org.nuxeo.ecm.automation.core.operations.notification.SendMail
Contributing Component org.nuxeo.ecm.core.automation.features.operations

JSON Definition

{
  "id" : "Document.Mail",
  "aliases" : [ "Notification.SendMail" ],
  "label" : "Send E-Mail",
  "category" : "Notification",
  "requires" : null,
  "description" : "Send an email using the input document to the specified recipients. You can use the HTML parameter to specify whether you message is in HTML format or in plain text. Also you can attach any blob on the current document to the message by using the comma separated list of xpath expressions 'files'. If you xpath points to a blob list all blobs in the list will be attached. Return back the input document(s). If rollbackOnError is true, the whole chain will be rollbacked if an error occurs while trying to send the email (for instance if no SMTP server is configured), else a simple warning will be logged and the chain will continue.",
  "url" : "Document.Mail",
  "signature" : [ "document", "document", "documents", "documents" ],
  "params" : [ {
    "name" : "from",
    "description" : null,
    "type" : "string",
    "required" : true,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "message",
    "description" : null,
    "type" : "string",
    "required" : true,
    "widget" : "MailTemplate",
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "subject",
    "description" : null,
    "type" : "string",
    "required" : true,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "HTML",
    "description" : null,
    "type" : "boolean",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ "false" ]
  }, {
    "name" : "Strict User Resolution",
    "description" : null,
    "type" : "boolean",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "bcc",
    "description" : null,
    "type" : "stringlist",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "cc",
    "description" : null,
    "type" : "stringlist",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "files",
    "description" : null,
    "type" : "stringlist",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "replyto",
    "description" : null,
    "type" : "stringlist",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "rollbackOnError",
    "description" : null,
    "type" : "boolean",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ "true" ]
  }, {
    "name" : "to",
    "description" : null,
    "type" : "stringlist",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "viewId",
    "description" : null,
    "type" : "string",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ "view_documents" ]
  } ]
}